﻿@{
    ViewBag.Title = "首页";
    Layout = null;
}

<!DOCTYPE html>
<html lang="en" ng-app="app">
<head>
    <meta charset="UTF-8">
    <title>网上订餐</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no">
    <link href="~/Content/Style/home.css" rel="stylesheet" />
    @*<link href="~/Content/Style/gobal.css" rel="stylesheet" />*@
    <script src="~/Content/Script/jquery-1.8.3.min.js"></script>
    <script src="~/Content/Script/angular.min.js"></script>
    <script src="~/Scripts/PageJs/Main.js"></script>
    <script src="~/Scripts/PageJs/Home.js"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            $(".rank").click(function () {
                $(".nav_list").toggle();
            });
            $(".screen").click(function () {
                $(".nav_list_2").toggle();
            });
            $(".classification").click(function () {
                $(".nav_list_3").toggle();
            });
            $(".discount_info").click(function () {


                $(this).parent().parent().next(".more").toggle();

            });
        });
        $scope.aa = 'a';//id的值，区分类型
        $scope.aa = $scope.users[0].id;//如果想要第一个值
    </script>
    
    @*<style>
        .cur {
            display: block!important;
        }
    </style>*@
    @*<link href="~/Content/Style/gobal.css" rel="stylesheet" type="text/css">*@
    @*<link href="~/Content/Style/home.css" rel="stylesheet" type="text/css">*@
    @*<link href="~/Content/Style/font-awesome.min.css" rel="stylesheet" type="text/css">*@
</head>

<body ng-controller="HomeCtrl">
    <!--头部-->
    <img class="banner" src="../../Content/images/123.jpg" />
    <div class="nav_box">
        <div class="seach">
            <input name="" ng-model="SearchWord.KeyWord" />
            <span class="sea"  ng-click="seach(SearchWord.KeyWord)">
                <img src="../../Content/images/search_icon.png" />
            </span>
        </div>
        <!----我是选择菜单列表，下拉可以选择---->
        <!---我是左边的列表--->
        <select class="r_nav" name="" id="" ng-change="selectPaiXu(chkPaiXu)" ng-model="chkPaiXu">
            <option  value="0">默认排序</option>
            <option  value="1">销量排序</option>
            <option  value="2">评论排序</option>
            <option  value="3">评分排序</option>
        </select>
        <!---我是中间的列表--->
        <select class="r_nav" id="" ng-change="selectMaxMon(chkMaxMon)" ng-model="chkMaxMon"><!--ng-change="selectMaxMon(chkMaxMon)" ng-model="chkMaxMon"> ng-change="selectFormMon(chkFormMon)" ng-model="chkFormMon"-->
            <option value="0">筛选</option>
            <option value="1">0元起送</option>
            <option value="2">免配送费</option>
        </select>
        <!---我是右边的列表--->
        <select class="r_nav" name="" selected='0' id="" ng-change="selectType(selectedSite.DictKey)" ng-model="selectedSite"  ng-options="x.DictName for x in types" >
            <option id="k" value="0">请选择</option>
            <option ng-repeat="d in types" value="d" style="overflow: hidden;">
               <!--<a href="" id="{{d.DictKey}}" ng-bind="d.DictName" ng-click="selectType(d.DictKey)">-->
            </option>
        </select>
        <div class="clearfix"></div>
    </div>
    <!------我是餐厅内容区------->
    <!--------我是餐厅---------->
    <div class="content" ng-repeat="item in shops">
        <div class="box">
            <a href="/Shop/Index?shopnumber={{item.MerID}}">
            <img ng-src="{{item.MerPic}}" @* alt="{{item.MerName}}"*@/>
            </a>
        </div>
        <div class="text">
            <h1>
                <a href="/Shop/Index?shopnumber={{item.MerID}}">
                    <span ng-bind="item.MerName"></span>
                </a>
            </h1>
            <div class="star_box">
                <div class="star" ng-if="item.StarCount/item.EvaCount < 1 || item.EvaCount < 1">
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <div class="clearfix"></div>
                </div>
                <div class="star" ng-if="item.StarCount/item.EvaCount >= 1 && item.StarCount/item.EvaCount < 2">
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <div class="clearfix"></div>
                </div>
                <div class="star" ng-if="item.StarCount/item.EvaCount >= 2 && item.StarCount/item.EvaCount < 3">
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <div class="clearfix"></div>
                </div>
                <div class="star" ng-if="item.StarCount/item.EvaCount >= 3 && item.StarCount/item.EvaCount < 4">
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_2.png" />
                    <img src="../../Content/images/star_2.png" />
                    <div class="clearfix"></div>
                </div>
                <div class="star" ng-if="item.StarCount/item.EvaCount >= 4 && item.StarCount/item.EvaCount < 5">
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_2.png" />
                    <div class="clearfix"></div>
                </div>
                <div class="star" ng-if="item.StarCount/item.EvaCount >= 5">
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <img src="../../Content/images/star_1.png" />
                    <div class="clearfix"></div>
                </div>
                <div class="fendiv" ng-if="item.StarCount/item.EvaCount < 1 || item.EvaCount < 1">
                    <p class="fen" ng-bind="item.StarCount/item.EvaCount|number:2"></p>
                </div>
                <div class="fendiv" ng-if="item.StarCount/item.EvaCount >= 1">
                    <p class="fen" ng-bind="(item.StarCount/item.EvaCount|number:2)+'分'"></p>
                </div>
                <p class="number" ng-bind="'总销量'+item.SalesCount">总销量</p>
                <div class="clearfix"></div>
            </div>
            <div class="price">
                <p>起送价：<span ng-bind="item.DelMaxMon/100+'元'"></span></p>
                <p id="peisong">配送费：<span ng-bind="item.DelFormMon/100+'元'"></span></p>
                <div class="clearfix"></div>
            </div>
            <span class="time" ng-bind="item.DelTime+'分'"></span>
        </div>


        <div class="clearfix"></div>
    </div>
    <!-----我是一个占位置的盒子----->
    <div class="kong"></div>
    <!---底部-->
    <div class="footer">
        <div ng-controller="AllLinkCtrl">
            <a id="current">
                <img src="../../Content/images/home.png">
                <span class="home_name">首页</span>
            </a>
            <a href="~/Classification/Index">
                <img src="../../Content/images/home.png">
                <span class="home_name">分类</span>
            </a>
            <a ng-click="gotoOrderList()">
                <img src="../../Content/images/mune.png">
                <span class="mune_name">订单</span>
            </a>
            <a ng-click="gotoInformation()">
                <img src="../../Content/images/man.png">
                <span class="user_name">我的</span>
            </a>
        </div>
    </div>
</body>

</html>
